import type { OrderSetting, OrderSettingParams } from '@/models/orderSetting'
import type { CommonResult } from '@/models/request'
import request from '@/utils/request'

export function getOrderSetting(id: number) {
  return request<CommonResult<OrderSetting>>({
    url: '/orderSetting/' + id,
    method: 'get',
  })
}

export function updateOrderSetting(data: OrderSettingParams) {
  return request<CommonResult>({
    url: '/orderSetting/update/' + data.id,
    method: 'post',
    data: data,
  })
}
